/************************************************************************
                        InterfaceLogic.h 
this class is a part of the Interface unit of Intersil
InterfaceLogic is responsible for communicating a request with the 
DataContainer, and processing its replies.
it does not alter the replies from the DataContainer.


* inherits from Object for future extendability.
*/
#ifndef INTERFACELOGIC_H
#define INTERFACELOGIC_H
#include "..\Shered\Object.h"
#include <memory>
using namespace std;
//class InterfaceLogic
class Interface;
class Object;
class Reply;
class Request;
class InterfaceLogic : virtual public Object
{
public:
	//ctor/dtor
	InterfaceLogic (Interface &t_ifc);
	virtual ~InterfaceLogic ();
	//sendRequest sends a request to DataContainer, and recieves its reply
	//it then processes the replies as follows:
	//when a user logges in his permission level,id,name is stored in Interface.
	//reply is returned, unchanged to calling method/object.
	//it does not alter the replies from the DataContainer.
	auto_ptr<Reply> sendRequest (const Request &request);
protected:
private:
	InterfaceLogic(const InterfaceLogic &ifcl);
	InterfaceLogic &operator=(const InterfaceLogic &rhs);
	Interface & m_ifc;
};
#endif // INTERFACELOGIC_H
